import React from "react";
import './new_module.css'
// const bg = {
//   height: '100%',
//   color: 'red',
//   //background: url("../../source/1.jpg"),
//   background: require("../static/images/head_bg.jpg"),
// };
class new_module extends React.Component{
   
    render(){
      let {title,lastName}=this.props.content
        return(
        // 子组件感受路由
         <div onClick={this.props.onClick}>
         {/* 子组件回传
          <div onClick={()=>this.props.onchild(1)}> 
         <div onClick={this.props.onchild.bind(this,title)}>    */}
          <div className='module'>
           {title}
            <div className='right_bg' style={{backgroundImage:"url("+ lastName +")"}}></div>
          </div>
        </div>
        )
    }
}
export default new_module